package com.example.kt_base.s3

//TODO 40.在Kotlin空合并操作符
fun main() {
    var name: String? = "derry"
    name = null

    //空合并操作符
    println(name ?: "原来你是null")


    //let函数+空合并操作符
    println(name?.let { "[it]" } ?: "原来是你null")


}
